
Blockly.defineBlocksWithJsonArray([{
  "type": "wait_seconds",
  // "message0": " wait %1 seconds",
  "message0": " 延时 %1 秒",
  "args0": [{
    "type": "field_number",
    "name": "SECONDS",
    "min": 0,
    "max": 600,
    "value": 1
  }],
  "previousStatement": null,
  "nextStatement": null,
  "colour": "%{BKY_LOOPS_HUE}"
}]);


Blockly.Lua['wait_seconds'] = function(block) {
  var seconds = Number(block.getFieldValue('SECONDS'));
  var code = 'waitForSeconds(' + seconds + ')\n';
  return code;
};

